package cn.bjit.mapper;
import cn.bjit.model.ProductDO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;


public interface ProductMapper extends BaseMapper<ProductDO> {
    //锁定商品记录
    int lockProductStock(@Param("productId") long productId, @Param("buyNum") int buyNum);

    //解锁商品存储
    void unlockProductStock(@Param("productId")Long productId, @Param("buyNum")Integer buyNum);
}
